#include"my_stdio.h"
#include"my_string.h"
#include<stdio.h>
int main()
{
    MyFILE* pf = mfopen("log.txt","a");
    if(pf==NULL)
    {
        return 1;
    }
    int cnt = 5;
    while(cnt)
    {
        char ch[64];
        snprintf(ch,"hello cqy :%d\n",cnt--);
        printf("%s\n",ch);
        mfwrite(ch,strlen(ch),pf);
    }
    mfclose(pf);
    printf("%d\n",my_strlen(ch));
    return 0;
}
